package cn.leonis.leetcode;

/**
 * @author Tobi
 * @date 2021-06-07 9:10
 * 链表
 */
public class ListNode {

    int val;
    public ListNode next = null;

    public ListNode(){

    }

    public ListNode(int val) {
        this.val = val;
        // next = null;
    }

    public ListNode(int val, ListNode next) {
        this.val = val;
        this.next = next;
    }

    @Override
    public String toString() {
        return "ListNode{" +
                "val=" + val +
                ", next=" + next +
                '}';
    }
}
